package com.elcom.roaming.common;

public class StringCouple {
	public static final int TYPE_MSISDN = 0;
	public static final int TYPE_IMSI = 2;
	public static final int TYPE_CALLING = 3;
	public static final int TYPE_MSRN = 4;

	private int typeNum1;
	private String number1;
	private int typeNum2;
	private String number2;

	public StringCouple(int typeNum1, String number1, int typeNum2,
			String number2) {
		super();
		this.typeNum1 = typeNum1;
		this.number1 = number1;
		this.typeNum2 = typeNum2;
		this.number2 = number2;
	}

	public int getTypeNum1() {
		return typeNum1;
	}

	public void setTypeNum1(int typeNum1) {
		this.typeNum1 = typeNum1;
	}

	public String getNumber1() {
		return number1;
	}

	public void setNumber1(String number1) {
		this.number1 = number1;
	}

	public int getTypeNum2() {
		return typeNum2;
	}

	public void setTypeNum2(int typeNum2) {
		this.typeNum2 = typeNum2;
	}

	public String getNumber2() {
		return number2;
	}

	public void setNumber2(String number2) {
		this.number2 = number2;
	}

	@Override
	public String toString() {
		String result = "";

		switch (typeNum1) {
		case TYPE_MSISDN:
			result += "msisdn=" + number1;
			break;
		case TYPE_IMSI:
			result += "imsi=" + number1;
			break;
		case TYPE_CALLING:
			result += "calling=" + number1;
			break;
		case TYPE_MSRN:
			result += "msrn=" + number1;
			break;
		default:
			result += "number1=" + number1;
			break;
		}

		result += " | ";
		
		switch (typeNum1) {
		case TYPE_MSISDN:
			result += "msisdn=" + number2;
			break;
		case TYPE_IMSI:
			result += "imsi=" + number2;
			break;
		case TYPE_CALLING:
			result += "calling=" + number2;
			break;
		case TYPE_MSRN:
			result += "msrn=" + number2;
			break;
		default:
			result += "number1=" + number2;
			break;
		}

		return result;
	}
}
